package com.ebs.md.api;

/**
 * Revision Author:
 *  $File: //depot/MarketData/commons-md-api/MAIN/src/main/java/com/ebs/md/api/IOrderBookManager.java $
 *  $Revision: #2 $
 *  $DateTime: 2012/05/15 08:24:55 $
 *  $Change: 111046 $
 *  $Author: Arik.Sher $
 */


public interface IOrderBookManager<BE extends IBookEntry, O extends IOrder>
extends IOrderBook<BE>
{
	/**
	 * 
	 * @param order - order to apply
	 */
	public void applyOrder(O order);
	
	/**
	 * reset both side's snapshots. meaning this one is the complete snapshot update.
	 * 
	 * @param   bidSideSnapshot - 
	 * @param offerSideSnapshot -
	 *  
	 * product - expected product of that book(should match to existing product...)
	 */
	public void resetWithSnapshot(ISnapshot<BE> bidSideSnapshot, ISnapshot<BE> offerSideSnapshot);

	/**
	 * 
	 * @param snapshot - represents only one side of the Book.  
	 */
	public void resetSnapshotSide(ISnapshot<BE> snapshot);
	
	/**
	 * 
	 * @param listener - single listener. 
	 */
	public void setOrderBookListener(OrderBookListener<IOrderBook<BE>, BE, O>  listener);
	
}
